package com.kingre.et.dao.jpa;

import java.util.List;

import com.kingre.et.dao.IResourceDAO;
import com.kingre.et.model.Resource;

public class ResourceDAOJPA extends GenericDAOJPA<Resource, Integer> implements
        IResourceDAO {

    @SuppressWarnings("unchecked")
    public List<Resource> findByType(String type) {
        return getJpaTemplate().find("FROM Resource p WHERE type = ? ORDER BY value DESC", type);
    }

}
